package com.example.studyllm.component.model;

import com.example.studyllm.bo.ModelBO;
import dev.langchain4j.model.chat.ChatLanguageModel;
import dev.langchain4j.model.chat.StreamingChatLanguageModel;
import dev.langchain4j.model.embedding.EmbeddingModel;

/**
 * @author wk
 */
public interface ChatModelBuilder {

    /**
     * 校验入参
     * @param modelBO
     */
    void checkParam(ModelBO modelBO);
    /**
     * 构建对话模型
     * @param modelBO
     * @return
     */
    ChatLanguageModel buildModel(ModelBO modelBO);

    /**
     * 构建对话模型（流模式）
     * @param modelBO
     * @return
     */
    StreamingChatLanguageModel buildStreamModel(ModelBO modelBO);

    /**
     * 构建向量模型
     * @param modelBO
     * @return
     */
    EmbeddingModel buildEmbeddingModel(ModelBO modelBO);

}
